package server.business.pojo;


import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

@TableName(value = "blood_processing")
@Data
public class BloodProcessing  implements Serializable {

    /**
     * 编号
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 创建时间
     */
    @TableField(value = "gmt_creat")
    private Date gmtCreat;

    /**
     * 修改时间
     */
    @TableField(value = "gmt_modified")
    private Date gmtModified;

    /**
     *
     */
    @TableField(value = "processing_id")
    private String processingId;

    /**
     *
     */
    @TableField(value = "processing_method")
    private String processingMethod;

    /**
     *
     */
    @TableField(value = "processing_state")
    private String processingState;


    /**
     * 血液编号
     */
    @TableField(value = "blood_id")
    private String bloodId;

    /**
     * 血袋编号
     */
    @TableField(value = "blood_bag_number")
    private Integer bloodBagNumber;
    /**
     * 扩展码
     */
    @TableField(value = "extend_code")
    private Integer extendCode;

    /**
     * 血液成分
     */

    @TableField(value = "blood_component")
    private String bloodComponent;

    /**
     *  ABO血型
     */
    @TableField(value = "abo_type")
    private String aboType;

    /**
     *  Rh血型
     */
    @TableField(value = "rh_type")
    private String rhType;

    /**
     *  规格
     */
    @TableField(value = "specification")
    private Float specification;

    /**
     *  失效时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @TableField(value = "failure_time")
    private Date failureTime;

    /**
     * 加工后血液成分
     */
    @TableField(value = "post_component")
    private String postComponent;

    /**
     * 加工后失效时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @TableField(value = "post_failure_time")
    private Date postFailureTime;


    /**
     * 逻辑删除
     */
    @TableLogic
    @TableField(value = "is_deleted")
    private Integer isDeleted;

    @TableField(exist = false)
    private static final long serialVersionUID = -8797207438706562604L;

}
